package com.neu.dao.impl;

import com.neu.dao.AdminDao;
import com.neu.dao.BaseDao;

import java.util.List;
import java.util.Map;

public class AdminDaoImpl extends BaseDao implements AdminDao {
    @Override
    public Map<String, Object> login(String name, String pwd) {
        Map<String,Object> map =null;
        String sql ="select * from tbl_admin where binary admin_name = ? and admin_pwd=MD5(?)";
        List<Map<String,Object>> list=super.executeQuery(sql,name,pwd);
        if (list.size()>0){
            map=list.get(0);
        }
        return map;
    }
}
